package tester;

import static org.junit.Assert.*;

import java.util.ArrayList;

import mock.MockChooseCourseLineItem;

import org.junit.Test;

import po.ChooseCoursePO;
import businesslogicservice.ChooseCourseLineItem;
import businesslogicservice.ChooseCourseList;

public class FindChooseCourseTest {

	@Test
	public void testFindAllChooseCourse() {
		MockChooseCourseLineItem mockChooseCourseLineItem
	     =new MockChooseCourseLineItem(new ChooseCoursePO(121250235, "ZouXuan", 0003, "Software Engineering"));
	ArrayList<ChooseCourseLineItem> chooseCourselist=new ArrayList<>();
	chooseCourselist.add(mockChooseCourseLineItem);
	ChooseCourseList chooseCourseList=new ChooseCourseList(chooseCourselist);
	ChooseCourseLineItem item=chooseCourseList.getChooseCourseList().get(0);

	
	assertEquals(121250235,item.getChooseCoursePO().getStudentId());
	assertEquals("ZouXuan", item.getChooseCoursePO().getStudentName());
	assertEquals(0003, item.getChooseCoursePO().getCourseId());
	assertEquals("Software Engineering", item.getChooseCoursePO().getCourseName());
	
	}
}
